a904a69712282c9f0bc9489546d5b1489980aa2e,central/src/main/java/org/glowroot/central/repo/GaugeNameDao.java,GaugeNameDao,store,#String#String#,75
Before Change
boundStatement.setString(i++, agentRollupId);
boundStatement.setString(i++, gaugeName);
boundStatement.setInt(i++, getMaxTTL());
return ImmutableList.of(Sessions.executeAsyncWithOnFailure(session, boundStatement,
() -> rateLimiter.invalidate(rateLimiterKey)));
}
private int getMaxTTL() throws Exception {
After Change
boundStatement.setString(i++, agentRollupId);
boundStatement.setString(i++, gaugeName);
boundStatement.setInt(i++, getMaxTTL());
ResultSetFuture future = Sessions.executeAsyncWithOnFailure(session, boundStatement,
() -> rateLimiter.invalidate(rateLimiterKey));
future.addListener(() -> cache.invalidate(agentRollupId), MoreExecutors.directExecutor());
return ImmutableList.of(future);
}